﻿using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Excel;
using OfficeOpenXml.Table;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ZhonTai.Industry.Services.AlarmRecord.Dto.Output
{
    [ExcelExporter(Name = "告警记录列表", TableStyle = TableStyles.Light9, AutoFitAllColumn = true, AutoFitMaxRows = 5000)]
    public class AlarmRecordExport
    {

        /// <summary>
        /// 工站代号
        /// </summary>
        [ExporterHeader(DisplayName = "工站代号", Format = "0", ColumnIndex = 2)]
        public string StationCode { get; set; }

        /// <summary>
        /// 工站名称
        /// </summary>
        [ExporterHeader(DisplayName = "工站名称", Format = "0", ColumnIndex = 3)]
        public string StationName { get; set; }

        /// <summary>
        /// 产线代号
        /// </summary>
        [ExporterHeader(DisplayName = "产线代号", Format = "0", ColumnIndex = 4)]
        public string LineCode { get; set; }

        /// <summary>
        /// 产线名称
        /// </summary>
        [ExporterHeader(DisplayName = "产线名称", Format = "0", ColumnIndex = 5)]
        public string LineName { get; set; }

        /// <summary>
        /// 报警开始时间
        /// </summary>
        /// <remarks>报警开始时间</remarks>
        [ExporterHeader(DisplayName = "报警开始时间", Format = "yyyy-MM-dd HH:mm:ss", ColumnIndex = 6)]
        public DateTime StartTime { get; set; }

        /// <summary>
        /// 报警结束时间
        /// </summary>
        /// <remarks>报警结束时间</remarks>
        [ExporterHeader(DisplayName = "报警结束时间", Format = "yyyy-MM-dd HH:mm:ss", ColumnIndex = 7)]
        public DateTime EndTime { get; set; }

        /// <summary>
        /// 循环时间
        /// </summary>
        /// <remarks>循环时间</remarks>
        [ExporterHeader(DisplayName = "持续时间", Format = "0", ColumnIndex = 8)]
        public double CycleTime { get; set; }

        /// <summary>
        /// 描述
        /// </summary>
        /// <remarks>描述</remarks>
        [ExporterHeader(DisplayName = "描述", Format = "0", ColumnIndex = 9)]
        public string? Description { get; set; }
    }
}